<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class Admin extends Model{
	protected $table = "admin";
	protected $primaryKey = "admin_id";
	public $timestamps = false;
	protected $hidden = ['password'];
	protected $fillable = ['admin_id', 'group_id', 'username', 'password', 'create_time'];
	
	public function hasOneAdminGroup(){
		return $this->hasOne('App\Models\AdminGroup', 'group_id', 'group_id');
	}
}
